const query = require('../index');

module.exports = {
  list(data) {
    const sql = `SELECT * FROM activity ORDER BY activity_id DESC LIMIT ?,?`;
    return query(sql, data);
  },
  check(data) {
    const sql = `UPDATE  activity SET state=? WHERE activity_id=?`;
    return query(sql, data);
  }
}